<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>

    <style>
        *{
            margin: 0;
        }
        .leftbox{
            width: 20%;
            height: 800px;
            background-color: lightgray;
            float: left;

        }

        .rightbox{
            width: 80%;
            height: 800px;
            background-color: aquamarine;
            float: left;
        }

        .title{
            text-align: center;
            background-color: coral;
            line-height: 30px;
            margin-top: 10px;
        }

        .hide{
            display: none;
        }
    </style>

    <script src="jquery-3.1.1.js"></script>
</head>
<body>


<div class="leftbox">
    <div class="item">
        <div class="title">菜单1</div>
        <div class="con">
            <div>111</div>
            <div>111</div>
            <div>111</div>
        </div>
    </div>
    <div class="item">
        <div class="title">菜单2</div>
        <div class="con hide">
            <div>222</div>
            <div>222</div>
            <div>222</div>
        </div>
        p
    </div>
    <div class="item">
        <div class="title">菜单3</div>
        <div class="con hide">
            <div>333</div>
            <div>333</div>
            <div>333</div>
        </div>
    </div>
</div>
<div class="rightbox"></div>


<script>
   $(".title").click(function () {


//         $(this).next().removeClass("hide");
//
//         $(this).parent().siblings().children(".con").addClass("hide")

         // jquery支持链式操作
         $(this).next().removeClass("hide").parent().siblings().children(".con").addClass("hide")



   })

</script>
</body>
</html>